<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <base href="<%=basePath%>">
    
    <title>My JSP 'right.jsp' starting page</title>
    
	<meta http-equiv="pragma" content="no-cache">
	<meta http-equiv="cache-control" content="no-cache">
	<meta http-equiv="expires" content="0">    
	<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
	<meta http-equiv="description" content="This is my page">
	
	<style type="text/css">
	body {
 		margin: 0px 0px;
		padding: 0px 0px;
		width: 100%;
  		height: 100%;
  	}
	
		
	table{
	width: 97%;
	}
	
	table tr{
		font-size:13px;
		line-height: 30px; 
		font-weight: 800;
	}
	
	</style>
	<script type="text/javascript">
	
		var lick;
		var over;
		var out;
		
		//鼠标点击按键
		function qclick(id) {
			lick=$("#lick").css("backgroundColor");
			$('#'+id).css("backgroundColor","#FFA500");
			var trs = $(".tr");
			for ( var int = 0; int < trs.length; int++) {
				if(trs[int].id!=id){
					$('#'+trs[int].id).css("backgroundColor","#E6E6FA");
				}
			}
			var sp = "span"+id.substring(2);
			var text = "${folder}/"+$('#'+sp).text();
			window.parent.contentframe(text); 
			window.parent.upfileName(text); 
		}
		//鼠标进入按键
		function qmouseover(id) {
			over=$("#over").css("backgroundColor");
			var s = $('#'+id).css("backgroundColor");
			if(s==out){
					$('#'+id).css("backgroundColor"," #EEE8AA");
			}	
		}
		//鼠标离开按键
		function qmouseout(id) {
			out=$("#out").css("backgroundColor");
			var s = $('#'+id).css("backgroundColor");
			if(s==over){
					$('#'+id).css("backgroundColor","#E6E6FA");
				}	
		}
	</script>
	
   <script type="text/javascript" src="./js/jquery-1.8.2.js"></script></head>
  		
  <body>
 
   <table>
   		<c:forEach items="${requestScope.logfilelist }" var="Str" varStatus="v">
			<tr id="tr${v.index}" class="tr" onclick="qclick(this.id)" onmouseover="qmouseover(this.id)" onmouseout="qmouseout(this.id)" 
			style="background-color: #E6E6FA">
				<td >&nbsp;<span id="span${v.index}">${Str}</span></td>
			</tr>
  		</c:forEach>
   </table>
  		<div id="lick" style="background-color: #FFA500"></div>
  		<div id="over" style="background-color: #EEE8AA "></div>
  		<div id="out" style="background-color: #E6E6FA"></div>
  </body>
</html>
